<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ page import ="readFromDB.GetStudent" %>
<%@ page import ="java.util.List" %>
<%@ page import ="classes.Students" %>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>查看个人信息</title>
	<div">
    <span>位置：查看个人信息</span>
     <li><a href="http://localhost:8080/my_term_project_xuanke/student/student_home.jsp">返回主页</a>	</li>
     <li><a href="http://localhost:8080/my_term_project_xuanke/student/choose_course.jsp">选课</a>	</li>
     <li><a href="http://localhost:8080/my_term_project_xuanke/student/showCourse.jsp">查看课表</a></li>	
	 <li><a href="http://localhost:8080/my_term_project_xuanke/student/updatePW.jsp">修改密码</a></li>	
	 <li><a href="http://localhost:8080/my_term_project_xuanke/student/alter_phone.jsp">修改密保手机</a></li>
    <ul>
    </ul>
    </div>
</head>
<body>
<table border="1" align="center">
       <tr>
         <th>学号</th>
         <th>姓名</th>
         <th>年级</th>
         <th>专业</th>
         <th>学院</th>
		 <th>密码</th>
		 <th>手机号码</th>		
		 <th>已修课程</th>	 
       </tr>
        <%
           String ID=(String)request.getSession().getAttribute("ID");
           GetStudent get=new GetStudent();
           List<Students> list = get.getByTableName("student");  
           for(Students student:list){
        	   if(ID.equals(student.getStuId()))
           
           {%>
         <tr>
              <td><%=student.getStuId() %></td>
              <td><%=student.getStuName() %></td>
              <td><%=student.getStuGrage()  %></td>
              <td><%=student.getStuProfess() %></td>
              <td><%=student.getStuInstitute()  %></td>
              <td><%=student.getStuPwd() %></td>     
              <td><%=student.getStuPhhone() %></td>
              <td><%=student.getStuCourselearned() %></td>
           </tr>
             <%}
           }
        %>
        
   </table>
</body>
</html>